var halvesAreAlike = function (s) {
    let arr = ['a', 'e', 'i', 'o', 'u', 'A', 'E', 'I', 'O', 'U']
    const a = s.slice(0, s.length / 2)
    const b = s.slice(s.length / 2, s.length)
    let counta = 0
    let countb = 0
    for (let i = 0; i < a.length; i++) {
        if (arr.includes(a[i])) {
            counta++
        }
    }
    for (let i = 0; i < b.length; i++) {
        if (arr.includes(b[i])) {
            countb++
        }
    }

    return counta === countb
}